package com.bbcare.department.plat.store.ibatis;

import java.util.List;
import java.util.Map;

import com.bbcare.department.plat.entity.DepartmentBasic;

/**
 * 科室基本信息存储
 * 
 * @author tao
 *
 */
public interface IDeparmentBasicDao {

    /**
     * 通过ID查询科室基本信息
     * 
     * @param id
     * @return
     */
    DepartmentBasic selectById(String id) throws Exception;

    /**
     * 创建科室资料信息
     * 
     * @param id
     * @return
     */
    int save(DepartmentBasic departmentBasic) throws Exception;

    /**
     * 更新客户资料信息
     * 
     * @return
     * @throws Exception
     */
    int update(DepartmentBasic departmentBasic) throws Exception;

    /**
     * 根据app科室id查询随访系统的关联科室id
     * 
     * @param refDeptId
     * @return list
     */
    List<DepartmentBasic> selectByRefDeptId(Map<String, Object> paramMap) throws Exception;
    
    //根据系统的departmentid 查询app端科室id
    DepartmentBasic selectAppDeptId(Map<String, Object> paramMap) throws Exception;

    /**
     * 查询医院科室信息
     * 
     * @param deptId,tenantId
     * @return list
     */
    List<DepartmentBasic> selectByTenantIdAndId(Map<String, Object> paramMap) throws Exception;
}
